﻿using SD.Infrastructure.RepositoryBase;
using SlamDunk.MES.Domain.Entities.ResourceContext;
using SlamDunk.ValueObjects.Enums;
using System;
using System.Collections.Generic;

namespace SlamDunk.MES.Domain.IRepositories.Interfaces.ResourceContext
{
    /// <summary>
    /// 物料定义仓储接口
    /// </summary>
    public interface IMaterialRepository : IAggRootRepository<Material>
    {
        #region # 分页获取物料定义列表 —— ICollection<Material> FindByPage(string keywords...
        /// <summary>
        /// 分页获取物料定义列表
        /// </summary>
        /// <param name="keywords">关键字</param>
        /// <param name="materialSourceType">物料来源类型</param> 
        /// <param name="hasLot">是否按批量管理</param>
        /// <param name="facilityIds">工厂模型Id集</param>
        /// <param name="enabled">是否启用</param>
        /// <param name="materialClassIds">物料类Id集</param>
        /// <param name="pageIndex">页码</param>
        /// <param name="pageSize">页容量</param>
        /// <param name="rowCount">总记录数</param>
        /// <param name="pageCount">总页数</param>
        /// <returns>物料定义列表</returns>
        ICollection<Material> FindByPage(string keywords, MaterialSourceType? materialSourceType, bool? hasLot, IList<Guid> facilityIds, bool? enabled, IList<Guid> materialClassIds, int pageIndex, int pageSize, out int rowCount, out int pageCount);
        #endregion
    }
}
